﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Twc.Deployment.Client.Logic.Commands.Parameters
{
    public class Setup :  BaseParameter
    {
        public Setup()
            : base("WSP Setup", "setup.bat")
        {
        }
    }

    public class Install : BaseParameter
    {
        public Install()
            : base("WSP Setup Install", "/install")
        {
        }
    }

    public class Uninstall : BaseParameter
    {
        public Uninstall()
            : base("WSP Setup Uninstall", "/uninstall")
        {
        }
    }

    public class SiteUrl : BaseParameter
    {
        public SiteUrl()
            : base("WSP Setup SiteUrl", "/siteurl")
        {
        }
    }

    public class WebUrl : BaseParameter
    {
        public WebUrl()
            : base("WSP Setup WebUrl", "/weburl")
        {
        }
    }

    public class Literal : BaseParameter
    {
        public Literal(string name, string parameter)
            : base(name, parameter)
        {
            if (!parameter.StartsWith("\""))
                this.Parameter = "\"" + this.Parameter;

            if (!parameter.EndsWith("\""))
                this.Parameter = this.Parameter  + "\"";

        }
    }

    public class STSADMOperation : BaseParameter
    {
        public STSADMOperation()
            : base("STSADM -o", "-o")
        {
        }
    }

    public class STSADM : BaseParameter
    {
        public STSADM()
            : base("STSADM", "STSADM.exe")
        {
        }
    }

    public class STSADMDeploySolution : BaseParameter
    {
        public STSADMDeploySolution()
            : base("STSADM DeploySolution", "deploysolution")
        {
        }
    }

    public class STSADMRetractSolution : BaseParameter
    {
        public STSADMRetractSolution()
            : base("STSADM Retract Solution", "retractsolution")
        {
        }
    }

    public class STSADMAddSolution : BaseParameter
    {
        public STSADMAddSolution()
            : base("STSADM Add Solution", "addsolution")
        {
        }
    }

    public class STSADMDeleteSolution : BaseParameter
    {
        public STSADMDeleteSolution()
            : base("STSADM Delete Solution", "deletesolution")
        {
        }
    }

    public class STSADMName : BaseParameter
    {
        public STSADMName()
            : base("STSADM Name", "-name")
        {
        }
    }

    public class STSADMUrl : BaseParameter
    {
        public STSADMUrl()
            : base("STSADM Url", "-url")
        {
        }
    }

    public class STSADMImmediate : BaseParameter
    {
        public STSADMImmediate()
            : base("STSADM Immediate", "-immediate")
        {
        }
    }

    public class STSADMAllowGacDeployment : BaseParameter
    {
        public STSADMAllowGacDeployment()
            : base("STSADM Allow Gac Deployment", "-allowgacdeployment")
        {
        }
    }

    public class STSADMForce : BaseParameter
    {
        public STSADMForce()
            : base("STSADM Force", "-force")
        {
        }
    }

    public class STSADMOverride : BaseParameter
    {
        public STSADMOverride()
            : base("STSADM Override", "-override")
        {
        }
    }

    public class STSADMFileName : BaseParameter
    {
        public STSADMFileName()
            : base("STSADM File name", "-filename")
        {
        }
    }

    public class STSADMBackup : BaseParameter
    {
        public STSADMBackup()
            : base("STSADM backup", "backup")
        {
        }
    }

    public class STSADMRestore : BaseParameter
    {
        public STSADMRestore()
            : base("STSADM restore", "restore")
        {
        }
    }

    public class STSADMOverwrite : BaseParameter
    {
        public STSADMOverwrite()
            : base("STSADM Overwrite", "-overwrite")
        {
        }
    }
}
